import configparser

import yaml

from utils.util import get_data_yaml_path, get_data_ini_path


def read_yaml():
    path=get_data_yaml_path()
    with open(path,encoding="utf8") as f:
        data=yaml.safe_load(f)
        return data

def read_ini():
    path=get_data_ini_path()
    config=configparser.ConfigParser()
    config.read(path,encoding="utf8")
    return config


if __name__ == '__main__':
    # print(read_yaml()["userinfo"]["username"])
    print(read_ini()["mysql"]["HOST"])